<template>
  <div class="app-container">
    <el-tabs v-model="activeTab" @tab-click="handleTabClick">
      <el-tab-pane label="K-fold Analysis Result" name="labKfoldResult" style="padding: 5px;">
        <LabkfoldResultContent :id="id" />
      </el-tab-pane>
      <el-tab-pane label="Analysis Details" name="labResult"  style="padding: 8px;">
        <LabResultContent :id="id" />
      </el-tab-pane>
    </el-tabs>
  </div>
</template>

<script>
import LabResultContent from "@/views/ade/lab/labresult.vue";
import LabkfoldResultContent from "@/views/ade/lab/labkfoldresult.vue";

export default {
  name: "LabDetail",
  components: {
    LabResultContent,
    LabkfoldResultContent
  },
  props: {
    id: {                 //传入的ID     LAB Analysis ID （一次分析任务的ID）
      type: Number,
      required: true
    }
  },
  data() {
    return {
      // 遮罩层
      loading: true,
      activeTab: 'labKfoldResult'
    };
  },
  created() {
    this.loading = false;
  },
  methods: {
    handleTabClick(tab) {
      console.log('当前激活的页签：', tab.name);
    }
  }
};
</script>

<style scoped>
/* 自定义Tab样式 */
.el-tabs__header {
  margin-bottom: 20px;
}

.el-tab-pane {
  padding: 15px;
}
</style>